import {createRouter, createWebHistory} from "vue-router";


const router = createRouter({
    history: createWebHistory(import.meta.env.BASE_URL),
    routes: [
        {   path: '/', name: 'login', component:() => import('../views/Login.vue'),},
        {   path: '/register', name: 'register', component:() => import('../views/Register.vue'),},
        {   path: '/userlist', name: 'userlist', component:() => import('../views/UserList.vue'),},
        {   path:'/mainframe', name:'mainframe', component:() => import('../views/MainFrame.vue'), children:[
            {   path: 'homepage', name: 'homepage', component: () => import('../views/HomePage.vue'),},
            {path: 'qa', name: 'qa', component: () => import('../views/QAPage.vue'),},
            {path: 'diabetesprediction', name: 'diabetesprediction', component: () => import('../views/DiabetesPrediction.vue'),},
            {path: 'knowledgebase', name: 'knowledgebase', component: () => import('../views/KnowledgeBase.vue'),},
            {path:'patientinformation', name: 'patientinformation', component: () => import('../views/PatientInformation.vue'),},
            {path:'exerciseAdvice', name: 'exerciseAdvice', component: () => import('../views/ExerciseAdvice.vue'),}
            ]
        }
    ]
})
export default router
